package com.rd.student.jiaji.class2.duyukun.Day0808;

public class Student {
    String name;
    int chinese;
    int math;
    int all;

    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", chinese=" + chinese +
                ", math=" + math +
                '}';
    }

    public void Student(String name, int chinese, int math) {
        int all = chinese + math;
        System.out.println(name + " " + chinese + " " + math + " " + all);
    }
    public int getAll(){
        return all;
    }
    public void setAll(int all){
        this.all = all;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getChinese() {
        return chinese;
    }

    public void setChinese(int chinese) {
        this.chinese = chinese;
    }

    public int getMath() {
        return math;
    }

    public void setMath(int math) {
        this.math = math;
    }
}
